CONFIG(debug, debug|release) {
    # debug configuration
    DESTDIR = debug
    MOC_DIR = obj/debug/moc
    OBJECTS_DIR = obj/debug
    UI_DIR = obj/debug/ui
    DEFINES += _DEBUG \
        DEBUG \
        ENABLE_LOGGING
}
else {
    # release configuration
    DESTDIR = release
    MOC_DIR = obj/release/moc
    OBJECTS_DIR = obj/release
    UI_DIR = obj/release/ui
    DEFINES += NDEBUG
}
QT -= core \
    gui
TARGET = test1
CONFIG += console
TEMPLATE = app
SOURCES += main.cpp
!win32-msvc*:DEFINES += HAVE_STDINT
DEFINES += ENABLE_DISASSEMBLER
INCLUDEPATH += .

# customize warnings for g++
*-g++* {
    CONFIG -= warn_off
    CONFIG -= warn_on
    QMAKE_CFLAGS += -Wall \
        -W \
        -Wno-unused
    QMAKE_CXXFLAGS += -Wall \
        -W \
        -Wno-unused
}

# customize warnings for msvc (deprecated declarations, unused arguments)
win32-msvc* {
    CONFIG -= warn_off
    CONFIG -= warn_on
    QMAKE_CFLAGS += -W4 \
        -wd4996 \
        -wd4100
    QMAKE_CXXFLAGS += -W4 \
        -wd4996 \
        -wd4100
}

# win32-version of qt creator requires getchar()
win32* {
    DEFINES += GETCHAR_REQUIRED
}

# project includes
include(asm/asm.pri)
include(base/base.pri)
include(os/os.pri)
include(utility/utility.pri)
include(templates/templates.pri)

# tests
include(tests/tests.pri)
